package com.naiterui.ehp.bs.im.vo.dto;

/**
 * 内部接口 患者信息
 * @author 王泽浩
 * @since 2.9.0
 */
public class PatientDTO implements java.io.Serializable {

    private static final long serialVersionUID = -1703589169193944833L;

    /**
     * 女：<code>GENDER_FEMALE</code>
     */
    public static final int GENDER_FEMALE = 0;
    /**
     * 男：<code>GENDER_MALE</code>
     */
    public static final int GENDER_MALE = 1;
    /**
     * 未知：<code>GENDER_UNKNOWN</code>
     */
    public static final int GENDER_UNKNOWN = 2;

    /**
     * 患者ID
     */
    private Long id;

    /**
     * 患者手机号
     */
    private String phone;

    /**
     * 患者unionId
     */
    private String unionId;

    /** 患者姓名 */
    private String name;

    /** 患者年龄 */
    private Integer age;

    /** 患者性别：0.女 1.男 */
    private Integer gender;

    /** 患者头像 */
    private String headUrl;

    public String getGenderStr() {
        return getGenderStr(this.gender);
    }

    public String getGenderStr(Integer gender) {
        if (null == gender) {
            return "未知";
        }
        String genderStr;
        switch (gender) {
            case GENDER_FEMALE:
                genderStr = "女";
                break;
            case GENDER_MALE:
                genderStr = "男";
                break;
            case GENDER_UNKNOWN:
                genderStr = "未知";
                break;
            default:
                genderStr = "未知";
                break;
        }
        return genderStr;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getUnionId() {
        return this.unionId;
    }

    public void setUnionId(String unionId) {
        this.unionId = unionId;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public Integer getGender() {
        return gender;
    }

    public void setGender(Integer gender) {
        this.gender = gender;
    }

    public String getHeadUrl() {
        return headUrl;
    }

    public void setHeadUrl(String headUrl) {
        this.headUrl = headUrl;
    }

    @Override
    public String toString() {
        return "PatientDTO [id=" + id + ", phone=" + phone + ", unionId=" + unionId + ", name=" + name + ", age=" + age + ", gender=" + gender
                + ", headUrl=" + headUrl + "]";
    }

}
